layui.config({
	base : "js/"
}).use(['form','layer','jquery','layedit','laydate'],function(){


    var userid=GetQueryString("usersid")

//
ajaxget("system/finduser",{"id":userid},function (data) {
	var info =data.data
    var userid=info.id
    var sharenum=info.sharenum
	var servicesname=info.servicesname;
	var address=info.zone;
	var answernum=info.answernum;
	var nowanswer=info.nowanswer;
	// var share=null;
	// if(info.share==1){
	// 	share="是"
	// }else if(info.share==0) {
     //    share="否"
	// }

	document.getElementById("nowanswer").value=nowanswer;
    document.getElementById("sharenum").value=sharenum;
    document.getElementById("userid").placeholder=userid;
    document.getElementById('servicesname').value=servicesname;
    document.getElementById('area').value=address;
    document.getElementById('answernum').value=answernum;


})


})


function GetQueryString(name)
{
    var reg = new RegExp("(^|&)"+ name +"=([^&]*)(&|$)");
    var r = window.location.search.substr(1).match(reg);
    if(r!=null)return  unescape(r[2]); return null;
}
function formatDateTime(inputTime) {
    var date = new Date(inputTime);
    var y = date.getFullYear();
    var m = date.getMonth() + 1;
    m = m < 10 ? ('0' + m) : m;
    var d = date.getDate();
    d = d < 10 ? ('0' + d) : d;
    var h = date.getHours();
    h = h < 10 ? ('0' + h) : h;
    var minute = date.getMinutes();
    var second = date.getSeconds();
    minute = minute < 10 ? ('0' + minute) : minute;
    second = second < 10 ? ('0' + second) : second;
    return y + '-' + m + '-' + d+' '+h+':'+minute+':'+second;
};